package hnlg.com.cn.hetongmanage.service;

import java.util.HashMap;
import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Propagation;
import org.springframework.transaction.annotation.Transactional;

import hnlg.com.cn.hetongmanage.mapper.HetongMapper;
import hnlg.com.cn.model.HetongVo;

@Service("HetongService")
@Transactional(value="txManager",rollbackFor=Exception.class)
public class HetongServiceImpl implements IHetongService {
    @Autowired HetongMapper obj;
	@Override
	public boolean addHetong(HetongVo vo) throws Exception {
		return obj.addHetong(vo);
	}

	@Override
	public boolean deleteHetong(String id) throws Exception {
		return obj.deleteHetong(id);
	}

	@Override
	@Transactional(propagation=Propagation.NOT_SUPPORTED,readOnly=true)
	public List<HetongVo>  queryHetong(HetongVo vo)throws Exception {
		return obj.queryHetong(vo);
	}

	@Override
	public boolean updateHetong(HetongVo vo) throws Exception {
		return obj.updateHetong(vo);
	}

	@Override
	@Transactional(propagation=Propagation.NOT_SUPPORTED,readOnly=true)
	public List<HetongVo> queryByMultiplePara(String jzmc, String quyu_id, String yzdh) throws Exception {
		return obj.queryByMultiplePara(jzmc,quyu_id,yzdh);
	}

	@Override
	public List<HetongVo> queryByHashMapPara(HashMap<String,String> map) throws Exception {
		
		return obj.queryByHashMapPara(map);
	}

	@Override
	public HetongVo queryvo(String id)throws Exception{
		return obj.queryvo(id);
	}
}
